      <?php
        include("seguridad.php");
        include("top.php");
	include("left.php"); ?>


	<div id="contentC">
	  <div class="center">
	    <h1>Aqui va el contenido</h1><br />

	  </div>
				


    <?php
        include("fachadaBD.php");
        $f = new fachadaBD();
        $options = $f->obtenerProcesadores();
        $marcas = $f->obtenerMarcas();
        $f->cerrar();
    ?>
        



<form name = "registro" action="insertProducto.php" method="POST" enctype="multipart/form-data">
	 
	<center><table border=0>
        <tr><td>Tipo de Laptop</td><td><select size="1" name="tipo">
				<option selected value=""> </option>
				<option  value="1">Laptop</option>
				<option  value="2">Minilaptop</option>
				</select></td></tr>
	<tr><td>Modelo</td><td><input type="text" name="modelo" size="20" value=""></td></tr>
        <tr><td>Marca</td><td><SELECT name="marca" >
                                    <OPTION VALUE=0>
                                    <?=$marcas?>
                                    </SELECT> </td></tr>
        <tr><td>C&oacute;digo</td><td><input type="text" name="codigo" size="20" value=""></td></tr>
        <tr><td>Precio</td><td><input type="text" name="precio" size="20" value=""></td></tr>
	<tr><td>Imagen Principal</td><td><input  type="file" name="imagenp"  value=""></td></tr>
	<tr><td>Imagen Peque</td><td><input type="file" name="imagenpeq" size="20" value=""></td></tr>
	<tr><td>Imagen Flash</td><td><input  type="file" name="flash" size="20" value=""></td></tr>
	<tr><td>Procesador</td><td><SELECT name="procesador">
                                    <OPTION VALUE=0>
                                    <?=$options?>
                                    </SELECT> </td></tr>
        <tr><td>Velocidad procesador</td><td><input type="text" name="velproc" size="20" value=""> GHZ</td></tr>
        <tr><td>Tipo de Memoria</td><td><select size="1" name="tipomem">
				<option selected value=""> </option>
				<option  value="DDR">DDR</option>
				<option  value="DDR2">DDR2</option>
				<option  value="DDR3">DDR3</option>
				</select></td></tr>
	<tr><td>Memoria</td><td><select size="1" name="memoria">
				<option selected value=""> </option>
				<option  value=1>1</option>
				<option  value=2>2</option>
				<option  value=3>3</option>
     				<option  value=4>4</option>
				<option  value=5>5</option>
                		<option  value=6>6</option>
				<option  value=7>7</option>
				<option  value=8>8</option>
				</select> GB</td></tr>
	<tr><td>Disco</td><td><select size="1" name="disco">
				<option selected value=""> </option>
				<option  value=40>40</option>
				<option  value=80>80</option>
				<option  value=100>100</option>
     				<option  value=120>120</option>
				<option  value=160>160</option>
                		<option  value=200>200</option>
				<option  value=250>250</option>
				<option  value=320>320</option>
                                <option  value=500>500</option>
				</select> GB</td></tr>
	<tr><td>Velocidad de Disco</td><td><select size="1" name="velodisc">
				<option selected value=""> </option>
				<option selected value="5400">5400</option>
				<option selected value="7200">7200</option>
				</select> RPM</td></tr>
        <tr><td>Idioma de Teclado</td><td><input type="radio" name="teclado" value="Ingl&eacute;s"> Ingl&eacute;s
                <input type="radio" name="teclado" value="Espa&ntilde;ol" checked> Espa&ntilde;ol</td></tr>
        	<tr><td>Pantalla </td><td><select size="1" name="pantalla">
				<option selected value=""> </option>
				<option  value=8.9>8.9</option>
				<option  value=10.1>10.1</option>
     				<option  value=12>12</option>
				<option  value=13.3>13.3</option>
                                <option  value=14>14</option>
     				<option  value=14.1>14.1</option>
				<option  value=15.4>15.4</option>
                		<option  value=15.6>15.6</option>
				<option  value=17>17</option>
                                </select> pulgadas</td></tr>
                <tr><td>Descripci&oacute;n pantalla</td><td><input type="text" name="pcoment" size="20" value=""></td></tr>
                <tr><td>Sistema Operativo</td><td><select size="1" name="sistema">
				<option selected value=""> </option>
				<option  value="windows vista">Windows Vista</option>
				<option  value="windows 7 starter">Windows 7 Starter</option>
				<option  value="windows 7 home premium">Windows 7 Home Premium</option>
     				<option  value="windows 7 profesional">Windows 7 Profesional</option>
				<option  value="windows 7 ultimate">Windows 7 Ultimate</option>
                                <option  value="windows 7 home basic">Windows 7 Home Basic</option>
                                </select></td></tr>
               <tr><td>Tarjeta de Video</td><td><input type="radio" name="tarjeta" value="dedicado"> Dedicado
                <input type="radio" name="tarjeta" value="compartido" checked> Compartido</td></tr>
               	<tr><td>Memoria de Video</td><td><input type="text" name="memvideo" size="20" value=""></td></tr>
        <tr><td>Puertos USB</td><td><input type="text" name="puertos" size="20" value=""></td></tr>
        <tr><td>Webcam</td><td><input type="checkbox" name="webcam" value="1"></td></tr>
        <tr><td>Resoluci&oacute;n de la Webcam</td><td><input type="text" name="camres" size="20" value=""></td></tr>
        <tr><td>Unidad de lectura</td><td><select size="1" name="unidad">
				<option selected value=""> </option>
				<option  value="CD/DVD-RW">CD/DVD-RW</option>
				<option  value="CD/DVD-RW CON LIGHTSCRIBE">CD/DVD-RW con lightscribe</option>
				</select></td></tr>
	<tr><td>Tipo de garantia</td><td><select size="1" name="garantia">
				<option selected value=""> </option>
				<option  value="1 a&ntilde;o de garant&iacute;a">1 a&ntilde;o de garant&iacute;a</option>
				</select></td></tr>
      	<tr><td>Tipo de entrega</td><td><select size="1" name="entrega">
				<option selected value=""> </option>
				<option  value="inmediato">Retiro inmediata personal- Env&iacute;o nacional</option>
      				<option  value="diasiguiente">Retiro personal - Env&iacute;o nacional al d&iacute;a siguiente</option>
				</select></td></tr>
       	<tr><td>Formas de pago</td><td><select size="1" name="pago">
				<option selected value=""> </option>
				<option  value="deposito">Deposito Bancario</option>
      				<option  value="transferencia">Transferencia</option>
				<option  value="tarjeta">Tarjeta de Cr&eacute;dito</option>
                                </select></td></tr>
        <tr><td>Wifi</td><td><input type="checkbox" name="wifi" value="1"></td></tr>
        <tr><td>Bluetooth</td><td><input type="checkbox" name="bluetooth" value="1"></td></tr>
        <tr><td>Bateria</td><td><select size="1" name="bateria">
				<option selected value=""> </option>
				<option  value=3>3 celdas</option>
				<option  value=4>4 celdas</option>
                                <option  value=6>6 celdas</option>
                                <option  value=8>8 celdas</option>
				<option  value=9>9 celdas</option>
     				</select> </td></tr>
        <tr><td>Puertos</td><td><table><tr><td>VGA <input type="checkbox" name="vga" value="1"></td>
                                        <td>NTSC/PAL <input type="checkbox" name="tv" value="1"></td>
                                        <td>Microfono <input type="checkbox" name="microfono" value="1"></td></tr>
                                        <tr>
                                        <td>Ethernet <input type="checkbox" name="rj45" value="1"></td>
                                        <td>Modem <input type="checkbox" name="rj11" value="1"></td>
                                        <td>HDMI <input type="checkbox" name="hdmi" value="1"></td></tr>
                                        
                                        </tr>
                                </table>
            </td></tr>
       	<tr><td>Otros</td><td><input type="text" name="otros" size="20" value=""></td></tr>
        <tr><td>Disponibildad</td><td><input type="checkbox" name="disp" value="1"></td></tr>
        <tr class=b><td width=90>Descripcion</td> <td><textarea name="descripcion" cols='20' rows='5' onKeyUp="return maximaLongitud(this,249)"></textarea></td></tr>

        </table></center>	<center><input type="button" value="enviar" name="enviar" onClick="javascript:comprueba();"></center>
</form>

<script language="JavaScript" type="text/javascript">

function comprueba(){

	if (document.forms.registro.modelo.value==""){
		alert("Debe indicar el nombre de modelo");
	}else{
            if (document.forms.registro.marca.value==""){
		alert("Debe indicar el nombre de la marca");
            }else{
                if (document.forms.registro.codigo.value==""){
                    alert("Debe indicar el c&oacute;digo de producto");
                }else{
                    document.registro.submit();
                }
            }
	}
}


</script>
</div>




<?php include("rightbottom.php");?>
	
